/**
 * @param {Egg.Application} app - egg application
 */
module.exports = app => {
  const { router, controller } = app;
  router.get('/', controller.home.index);

  router.post('/login', controller.user.login);
  router.post('/register', controller.user.register);
  router.get('/getItem', controller.shop.getItem);
  router.get('/ssItem', controller.shop.ssItem);
  router.insert('/insertItem', controller.shop.insertItem);
  router.update('/updateItem', controller.shop.updateItem);
  router.delete('/deleteItem', controller.shop.deleteItem);
};
